﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using Microsoft.SharePoint; 
using System.Reflection;
using Microsoft.SharePoint.Utilities;
using System.IO;
using iwss.Document.Layouts.Services;

namespace iwss.Document.Layouts.AjaxServices
{
    /// <summary>
    /// Handler1 的摘要说明
    /// </summary>
    public class ServiceLocator : AjaxServicesBase
    {
        public override void ProcessRequest(HttpContext context)
        {
            base.ProcessRequest(context);

            string ActionType = context.Request["ActionType"].ToLower();
            AjaxResult result = null;

            switch (ActionType)
            {
                case "fileaction":
                    result = new FileAction().Excute(context);
                    break;
                case "receive":
                    result = new Receive().Excute(context);
                    break;
                case "other":
                    result = new Other().Excute(context);
                    break;
            }

            base.SendAjaxResult(context, result);
        }


        public bool IsReusable
        {
            get
            {
                return false;
            }
        }
    }
     
}